<% layout('layout') %><!--加载全局布局文件-->

<div class='' style='background: #EEE;' ng-controller="ConfirmPackageCtrl">
    <div data-ng-init="load(<%= balance %>,<%= total %>,'<%= aid%>')"></div>
    <form>
        <div class='am-margin-top-0 am-padding-sm' style='background: #FFF;' ng-click="getAllAddr()">
            <div class='' >
            <span style='font-size: 15px;'>
                <span style="color: red;">送至</span>　<span ng-bind="sendAddr.address"></span><br>
                &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span ng-bind="sendAddr.name"></span> <span ng-bind="sendAddr.phone"></span>
            </span>
            <span style='font-size: 12px;color:#AAA;float: right;'>
                收货地址 <i class='am-icon-chevron-right'></i>
            </span>
                <input type="hidden" ng-model="addrId"/>
                <input type="hidden" ng-model="aid" />
                <input type="hidden" ng-model="total" />
                <input type="hidden" ng-model="balance" />
            </div>
        </div>

        <div class='am-margin-top-sm am-padding-sm' style='background: #FFF;'>
            <div class='' >
            <span style='font-size: 15px;'>
                配送方式
            </span>
            <span style='font-size: 15px;float: right;'>
                果然100送货上门
            </span>
            </div>
        </div>

        <div class='am-margin-top-sm am-padding-sm' style='background: #FFF;'>
            <div class='' >
            <span style='font-size: 15px;'>
                支付方式
                <hr data-am-widget="divider" style="" class="am-divider am-divider-default am-margin-0 " />
            </span>
            </div>
            <div class='' >
            <span style='font-size: 15px;'>

                <p class="am-margin-vertical-xs">
                    <input type="radio" name="radioPay" value="hdfk_pay">&nbsp;货到付款&nbsp;&nbsp;&nbsp;
                    <input type="radio" name="radioPay" value="ye_pay">&nbsp;余额支付&nbsp;&nbsp;&nbsp;
                    <input type="radio" name="radioPay" value="wx_pay" checked>&nbsp;微信支付&nbsp;&nbsp;&nbsp;
                </p>
                <hr data-am-widget="divider" style="" class="am-divider am-divider-dotted am-margin-0" />
            </span>
            </div>
        </div>

        <div class='am-margin-top-sm am-padding-xs' style='background: #FFF;'>
            <div data-am-widget="list_news" class="am-list-news am-list-news-default" >
                <div class="am-list-news-bd">
                    <ul class="am-list">
                        <% cart.forEach(function(c){ %>
                        <li class="am-g am-list-item-desced am-padding-vertical-0 am-list-item-thumbed am-list-item-thumb-bottom-left" style="height: 80px;">
                            <div class="am-u-sm-3 am-list-thumb" style="max-height: none !important;">
                                <a href="#" class="">
                                    <img src="<%= c.img%>" style="width:78px;height:78px;" />
                                </a>
                            </div>
                            <div class=" am-u-sm-9  am-list-main">
                                <div class="am-list-item-text" style="margin-top:1rem !important;">
                                    &nbsp;<%= c.pname +' '+ c.sname %>
                                </div>
                                <div class="am-list-item-text color-DE0000 font-size-24p font-weight-700">
                                    &nbsp;单价：<span style="color: red;">¥<%= c.price%></span>
                                </div>
                                <div class="am-list-item-text color-999999">
                                    &nbsp;数量：<%= c.size%>
                                </div>
                            </div>
                            <div class=" am-u-sm-2  am-list-main text-center">
                            </div>
                        </li>
                        <%});%>
                    </ul>
                </div>
            </div>
        </div>
        <div class='am-margin-top-sm am-padding-sm more-service am-padding-vertical-xs' style='background: #FFF;'>
            <textarea class="" rows="2" id="doc-ta-1" style="width: 100%;font-size: 13px;" placeholder="亲,留言写在这里" ng-model="remark"></textarea>
        </div>

        <div class="am-modal am-modal-prompt scor-left-0 scor-bg-F8F8F8 "tabindex="-1" id="form-alert">
            <div class="am-modal-dialog scor-width-height-100 am-margin-0">
                <span data-am-modal-close  class="am-close am-close-alt am-close-spin am-icon-times am-align-right am-margin-right-sm am-margin-top-xs"></span>
                <div class="scor-height-40"></div>
                <div class="am-modal-hd scor-color-gr-font scor-font-size-22 scor-font-weight-700 am-padding-top-lg" ng-bind="formTitle"></div>
                <div ng-repeat="addr in data" class="am-margin-sm scor-border-radius-5 scor-border-bbb scor-border-set-{{addr.isDefault}}">
                    <div ng-click="setSendAddr($index,addr)" class="am-text-left">
                        <p class="am-margin-sm">
                            <span class="scor-color-red scor-font-weight-700">收&nbsp;&nbsp;件&nbsp;&nbsp;人&nbsp;：</span>
                            <span ng-bind="addr.name"></span>
                            <span class="am-margin-left" ng-bind="addr.phone"></span>
                        </p>
                        <p class="am-margin-sm am-margin-top-0">
                            <span class="scor-color-red scor-font-weight-700 ">地&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;址：</span>
                            <span ng-bind="addr.address"></span>
                        </p>
                    </div>
                </div>
                <div ng-click="toAddAdder()" class="am-margin-sm scor-color-008000 am-align-left">
                    <i  class="am-icon-plus-circle"></i>&nbsp;<span class="scor-color-008000">新增地址</span>
                </div>
            </div>
        </div>

        <div data-am-widget="navbar" class="am-navbar am-cf am-navbar-default " id="navbar" >
            <div class="am-navbar-nav am-cf am-avg-sm-4" style="background: #EEEEEE !important;">
                <div class="am-g am-padding-0 am-margin-0">
                    <div class="am-u-sm-3 am-padding-0 am-margin-0">
                        <span style="color: red;" >合计:¥<span ng-bind="total"></span></span>
                    </div>
                    <div class="am-u-sm-3">
                        <button type="button" id="qr" name="qr" class="am-btn am-btn-warning am-radius" ng-click="addOrder(<%= isPackage %>)">确认</button>
                    </div>
                </div>
            </div>
        </div>
    </form>
</div>

<% block('footer').append('<script src="'+CDN+'script/conpackagefirm.js"></script>') %>